<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<script>
		window.onload = function () {
			p = document.getElementsByTagName("p")
			box = document.getElementsByClassName("box")
			a = document.getElementById("title")
			console.log(p)
			console.log(box)
			console.log(title)
			p[0].style.color="red";
			title.style.color = "blue";
		}
	</script>
</head>
<body>
	<p>学并思1</p>
	<span class="box">jjj</span>
	<a id="title" href="">打垮一下</a>
	<!-- <p>学并思2</p> -->
</body>
</html>